<html>
<head><meta charset="utf-8"><title>Github PR · t-compiler/help · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/index.html">t-compiler/help</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/Github.20PR.html">Github PR</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="203460846"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/Github%20PR/near/203460846" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> sHaDoW <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/Github.20PR.html#203460846">(Jul 10 2020 at 01:26)</a>:</h4>
<p>If this is not the place to ask for help about this topic, please redirect me to where i can get help for my problem. :)</p>
<p>I'm very new to contributing code in general, and a noob at github. I created 2 functions for rust that i thought were necessary, and i tried to submit them, but the "pr checks" doesn't  seem to accept the code, i tested the code on my computer and it works fine, it's only two functions nothing crazy (it should run). I've been racking my brain about why it's not building, it keeps saying "error: function is never used", that being the only 2 errors, (one for each function). I have no idea if i'm being dumb, but i may need some guidance on how to contribute code. If you want to see the code in question the link is: (<a href="https://github.com/rust-lang/rust/pull/74178">https://github.com/rust-lang/rust/pull/74178</a>).</p>



<a name="203473065"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/Github%20PR/near/203473065" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/Github.20PR.html#203473065">(Jul 10 2020 at 06:22)</a>:</h4>
<p>we use <a href="https://github.com/rust-lang/rustfmt/">https://github.com/rust-lang/rustfmt/</a> to format both the standard library + the compiler.</p>
<p>You can run <code>./x.py fmt</code> to fix the current errors.</p>



<a name="203530924"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/Github%20PR/near/203530924" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/Github.20PR.html#203530924">(Jul 10 2020 at 16:48)</a>:</h4>
<p>If it says function not used, that might not show with fmt. Try <code>x.py check</code> which should reproduce the error.</p>



<a name="203531428"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/Github%20PR/near/203531428" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/Github.20PR.html#203531428">(Jul 10 2020 at 16:53)</a>:</h4>
<p>You may also have forgotten to put <code>pub</code> on the functions, without that they won't be usable outside the standard library itself</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>